import request from "@/utils/request";

// 查询保险管理列表
export function listInsurance(query) {
  return request({
    url: "/cld/insurance/list",
    method: "get",
    params: query,
  });
}

// 保险统计
export function insuranceStatistics(query) {
  return request({
    url: "/cld/insurance/insuranceStatistics",
    method: "get",
    params: query,
  });
}

// 保险头部统计
export function selectCldInsuranceAnalyze() {
  return request({
    url: "/cld/insurance/selectCldInsuranceAnalyze",
    method: "get",
  });
}

// 查询保险管理列表
export function getListInsurance(query) {
  return request({
    url: "/cld/insurance/getList",
    method: "get",
    params: query,
  });
}

// 查询保险管理详细
export function getInsurance(insuranceId) {
  return request({
    url: "/cld/insurance/" + insuranceId,
    method: "get",
  });
}

// 新增保险管理
export function addInsurance(data) {
  return request({
    url: "/cld/insurance",
    method: "post",
    data: data,
  });
}

// 修改保险管理
export function updateInsurance(data) {
  return request({
    url: "/cld/insurance",
    method: "put",
    data: data,
  });
}

// 删除保险管理
export function delInsurance(insuranceId) {
  return request({
    url: "/cld/insurance/" + insuranceId,
    method: "delete",
  });
}

// 查询保险理赔明细列表
export function listInsuranceDetails(query) {
  return request({
    url: "/cld/insuranceDetails/list",
    method: "get",
    params: query,
  });
}

// 查询保险理赔明细详细
export function getInsuranceDetails(insuranceDetailsId) {
  return request({
    url: "/cld/insuranceDetails/" + insuranceDetailsId,
    method: "get",
  });
}

// 新增保险理赔明细
export function addInsuranceDetails(data) {
  return request({
    url: "/cld/insuranceDetails",
    method: "post",
    data: data,
  });
}

// 修改保险理赔明细
export function updateInsuranceDetails(data) {
  return request({
    url: "/cld/insuranceDetails",
    method: "put",
    data: data,
  });
}

// 删除保险理赔明细
export function delInsuranceDetails(insuranceDetailsId) {
  return request({
    url: "/cld/insuranceDetails/" + insuranceDetailsId,
    method: "delete",
  });
}

// 关联人员提交
export function relatedPersonnel(data) {
  return request({
    url: "/cld/insurance/relatedPersonnel",
    method: "post",
    data: data,
  });
}

// 保险关联人员查询
export function selectInsuranceStaff(query) {
  return request({
    url: "/cld/insurance/selectInsuranceStaff",
    method: "get",
    params: query,
  });
}

// 历史操作记录统计
export function selectCldInsuranceStaffStatisticsList(query) {
  return request({
    url: "/cld/insurance/selectCldInsuranceStaffStatisticsList",
    method: "get",
    params: query,
  });
}

// 历史操作记录明细
export function selectCldInsuranceStaffList(query) {
  return request({
    url: "/cld/insurance/selectCldInsuranceStaffList",
    method: "get",
    params: query,
  });
}
